/**************************************************************************************
*
*	Copyright (C) 2009 - 2012 Brent Andrew O. Chua - See LICENSE.txt for more info.
*		
*	Filename	-	Event.h
*
*	Description -	Event class to be used by the event manager
*
*	Comments	-
*
*	Modification History:
*			Name			   Date					Description
*			MrCodeSushi	-	03/07/2009	-	Creation of this file
**************************************************************************************/
#ifndef _PSX_EVENT_H_
#define _PSX_EVENT_H_

#include "PulseSTD.h"
#include "StringID.h"

namespace Pulse
{
	//typedef StringID EEvent;
	PSX_EnumBegin( EEvent )

		// Input Device Events
		INPUT_KEY_UP,
		INPUT_KEY_DOWN,
		INPUT_MOUSE_MOVE,
		INPUT_MOUSE_BUTTONUP,
		INPUT_MOUSE_BUTTONDOWN,

		// Windowing System Events
		WINDOW_GAIN_FOCUS,			// Done through trigger
		WINDOW_LOSE_FOCUS,			// Done through trigger
		WINDOW_SIZE_START,
		WINDOW_SIZE_END,
		WNDOW_MOVE_START,
		WINDOW_MOVE_END,
		WINDOW_RELEASE_SWAPCHAIN,	// Done through trigger
		WINDOW_NEW_SWAPCHAIN,		// Done through trigger

		// WindowView Events
		WINDOW_VIEW_RESIZE,
		WINDOW_VIEW_DESTROY,		// Called just before it is destroyed

		// Scene events
		SCENE_NEW_ACTIVE_CAMERA,

		// Actor and Component System Events
		// TODO: Add an ACTOR/COMPONENT prefix...
		TRANSFORM,

		RENDER,

		COMPONENT_ADD,
		COMPONENT_REMOVE,

		// Component Model Filter 
		MODEL_UNLOAD,
		MODEL_LOADED,

		// Component Physics
		COLLISION_ENTER,
		COLLISION_STAY,
		COLLISION_EXIT,

	PSX_EnumEnd()

	class IEvent
	{
	public:

		IEvent( const FLOAT timeStep = 0.0f ) : m_timeStep( timeStep ) { }

		virtual ~IEvent( void ) { }

		virtual const EEvent::Type GetEventType( void ) const = 0;

		float GetTimeStep( void ) const { return m_timeStep; }

	private:

		const FLOAT m_timeStep;

	};

}
#endif /* _PSX_EVENT_H_ */